#include <iostream>
#include "lexer.h"
#include "error.h"
#include "parser.h"
#include "table.h"
using namespace std;

int main()
{
	// table["pi"] = 3.1415926;
	// table["e"] = 2.7172818;  

	while (cin) {
		Lexer::get_token();
		if (Lexer::curr_tok == Lexer::END) 	break;
		if (Lexer::curr_tok == Lexer::PRINT) continue;
        Lexer::output_token();
        cout<<"output:"<<Parser::expr(false)<<endl;
    }

	return Error::no_of_errors;
}
